package com.mis.pos.entity;

import com.mis.pos.base.entity.BaseEntity;
import lombok.Data;

import javax.persistence.Entity;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * @Description 商品实体
 * @Author yuxiang
 * @CreatedDate 2019/10/30 12:04
 */
@Entity
@Table(name = "item")
@Data
public class ItemEntity extends BaseEntity implements Serializable {

    /**
     * 商品名称
     */
    private String itemName;

    /**
     * 价格
     */
    private Double price;

    /**
     * 商品牌子
     */
    private String brand;

    /**
     * 是否在售卖 1表示售卖中 0表示已经下架
     * 默认售卖中
     */
    private int isSaled = 1;


    public String getItemName() {
        return itemName;
    }

    public void setItemName(String itemName) {
        this.itemName = itemName;
    }

    public Double getPrice() {
        return price;
    }

    public void setPrice(Double price) {
        this.price = price;
    }

    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public int getIsSaled() {
        return isSaled;
    }

    public void setIsSaled(int isSaled) {
        this.isSaled = isSaled;
    }

    public ItemEntity(){}

    public ItemEntity(String itemName, Double price, String brand, int isSaled) {
        this.itemName = itemName;
        this.price = price;
        this.brand = brand;
        this.isSaled = isSaled;
    }
}
